<?php
(!defined('IN_TOA') || !defined('IN_ADMIN')) && exit('Access Denied!');
/*
	[天生创想] (C)2008-2011 515158 Inc.
	This is NOT a freeware, use is subject to license terms
    URL:http://www.515158.com/
*/

//if ( !is_superadmin() && !check_purview('manage_link') ) prompt('对不起，你没有权限执行本操作！');
//初始化信息，进入表单页面
empty($do) && $do = 'list';
if ($do == 'list') {
	include_once('template/password.php');

} elseif ($do == 'save') {
	
	$savetype = getGP('savetype','P');
	$id = $_USER->id;
	//echo $id;
	//exit;
	$user = array(
		'password' => md5(getGP('password','P'))
	);
	
	update_db('user',$user, array('id' => $id));
	//echo $fatherid;
	//exit;
	goto_page('admin.php?ac=password&fileurl=user&message=1');
	

}
?>